﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DARE
{
    /// <summary>
    /// Represents a class with the four values representing : Top, Bottom, Left, Right
    /// </summary>
    public class SPositionsTBLR
    {
        private float m_top;
        private float m_bottom;
        private float m_left;
        private float m_right;

        public float Top { get { return m_top; } set { m_top = value; } }
        public float Bottom { get { return m_bottom; } set { m_bottom = value; } }
        public float Left { get { return m_left; } set { m_left = value; } }
        public float Right { get { return m_right; } set { m_right = value; } }
        public float All
        {
            set { m_top = value; m_bottom = value; m_left = value; m_right = value; }
        }

        public static bool operator !=(SPositionsTBLR p0, SPositionsTBLR p1)
        {
            if (p0.Bottom != p1.Bottom)
                return true;
            if (p0.Top != p1.Top)
                return true;
            if (p0.Left != p1.Left)
                return true;
            if (p0.Right != p1.Right)
                return true;
            return false;
        }

        public static bool operator ==(SPositionsTBLR p0, SPositionsTBLR p1)
        {
            return !(p0 != p1);
        }

        public override bool Equals(object obj)
        {
            return base.Equals(obj);
        }

        public override int GetHashCode()
        {
            return base.GetHashCode();
        }
    }
}
